#ifndef _LIST_H
#define _LIST_H

#define DEBUGMOD //start debug log mod
#ifdef DEBUGMOD
#define LOG(s,...)  printf("LOG: function:%s -- "s"\n", __FUNCTION__ , ##__VA_ARGS__);
#else
#define LOG(s,...)
#endif

typedef enum BOOLenum{FALSE, TRUE} BOOL;
typedef int elemType;
typedef struct Nodestru{
    elemType elem;
    struct Nodestru* next;
} *ptrNode, Node;

typedef struct Liststru{
    int count;
    int length;
    ptrNode head;
} *ptrList, List;

void list_create(ptrList list, int const len);
void list_print(ptrList list);
BOOL list_isFull(ptrList list);
BOOL  list_isEmpty(ptrList list);
void list_append(ptrList list, int const elem);
void list_insert(ptrList list, int const pos , int const elem);

#endif // _LIST_H
